

export class GlobalData {

    name: string = '小明';
    info: string = 'xin';
    gold: number = 0;
    diamond: number = 9000;
    progress: number = 0;
    icon: number = 0;

    check = {
        selectA: true,
        selectB: true,
        selectC: true,
    }
    
    obj = {
        progress: 0
    }

    array = [
        { name: 's1', age: 18, sex: 0 },
        { name: 's2', age: 16, sex: 1 },
        { name: 's3', age: 12, sex: 2 },
    ]

    menu = {
        state: 0
    }

    equips = [3,5,12,7,45,1,-1]

}


export let defaultData = new GlobalData();


export let replaceData = new GlobalData();
replaceData.array = [
    { name: 'c1', age: 22, sex: 5 },
    { name: 'c2', age: 26, sex: 6 },
    { name: 'c3', age: 25, sex: 7 },
];
replaceData.name = '小红';
replaceData.diamond = 888;
replaceData.progress = 10;
replaceData.gold = 100;
replaceData.check = {
    selectA: false,
    selectB: false,
    selectC: false,
}
replaceData.obj = {
    progress: 10
};
replaceData.equips = [0,1,2,3,4,5,6,7,8];